#include <iostream>
#include <opencv2/opencv.hpp>
using namespace cv;
using namespace std;

int main() {
  Mat src1 = imread("../images/2.jpg");
  Mat src2 = imread("hlstest.jpg");
  if (src1.empty() || src2.empty()) {
    cout << "could not load image.." << endl;
    return -1;
  }
  Mat dst;
  double alpha = 0.5;
  if (src1.size() == src2.size() && src1.type() == src2.type()) {
    addWeighted(src1, alpha, src2, alpha, 0.0, dst);
  } else {
    return -1;
  }

  namedWindow("opencv setup demo", CV_WINDOW_AUTOSIZE);
  imshow("opencv setup demo", dst);
  waitKey(0);
  return 0;
}